<style type="text/css">
		<!--
		A:link        {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
		A:visited     {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: none; color: #0000ff}
		A:hover       {font-family: helvetica, arial, geneva, sans-serif; font-size: x-small; text-decoration: underline; color: #FF0000}
		th            {font-family: helvetica, arial; color : blue; font-size:85%; background : lightgrey; border-right:black solid 1pt; border-bottom:black solid 1pt;}
		//-->
		</style><hr><a name="_C_GRID"><div style="background-color:yellow;font-family:courier new;"></a>CLASS <b>Grid</b></div>
<i>(Defined in: jpgraph.php : 3331)</i><table border=1><tr><td>&nbsp;<a href="Grid.html" style="font-family:arial;font-weight:bold;color:darkblue;">Grid</a>&nbsp;</td></tr><tr><td valign=top>&nbsp;<a href="Grid.html#_GRID_SETCOLOR">SetColor()</a>&nbsp;<br>
&nbsp;<a href="Grid.html#_GRID_SETFILL">SetFill()</a>&nbsp;<br>
&nbsp;<a href="Grid.html#_GRID_SETLINESTYLE">SetLineStyle()</a>&nbsp;<br>
&nbsp;<a href="Grid.html#_GRID_SETWEIGHT">SetWeight()</a>&nbsp;<br>
&nbsp;<a href="Grid.html#_GRID_SHOW">Show()</a>&nbsp;<br>
</td></tr></table>&nbsp;<p><div style="font-weight:bold;font-family:arial;font-size:100%;">Class usage and Overview</div>This class is used to hold all properties of the gridline for a specific axis. The grid setting is accessed through the xgrid and ygrid properties of graph.

By default JpGraph has grid lines for Y-lines turned on and gridlines for X-axis turned off.

 <p> &nbsp;
<hr><span style="font-family:arial;font-size:120%;font-weight:bold;">Class Methods</span><hr><p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_GRID_SETCOLOR"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetColor($aMajColor,$aMinColor)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Set color of grid lines</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aMajColor</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'>&nbsp;</td><td>Major color</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aMinColor</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
false</font>
</td><td>Minor color</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set color of grid lines&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$graph-&gt;xgrid-&gt;SetColor('lightblue');</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_GRID_SETFILL"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetFill($aFlg,$aColor1,$aColor2)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify fill style for grid</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aFlg</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
true</font>
</td><td>Flag, True=enable fill</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aColor1</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
'lightgray'</font>
</td><td>Fill color 1</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aColor2</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
'lightblue'</font>
</td><td>Fill color 2</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>The area between the gridline can be filled with two alternating colors. This method specifies this style. See 'filledgridex1.php' for an example of this. By using this feature with alpha-blending you can achieve very nice layouts.
&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
//&nbsp;Use&nbsp;50%&nbsp;blending<br />$graph-&gt;ygrid-&gt;SetFill(true,'#EFEFEF@0.5','#BBCCFF@0.5');<br />$graph-&gt;ygrid-&gt;Show();<br />$graph-&gt;xgrid-&gt;Show();<br /></font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_GRID_SETLINESTYLE"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetLineStyle($aType)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify if grid line should be dashed, dotted or solid</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aType</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'>&nbsp;</td><td>String to specify line type</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify if grid should be dashed, dotted or solid. The type is specified with a string which can be either "solid", "dashed" or "dotted".
&nbsp;<br>
 &nbsp; <div style="font-weight:bold;font-family:arial;font-size:85%;">See also</div><a href="Image.html#_IMAGE_SETLINESTYLE">Image::SetLineStyle</a>
<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$graph-&gt;ygrid-&gt;SetLineStyle('dashed');</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_GRID_SETWEIGHT"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;SetWeight($aWeight)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Set line weight for grid line</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aWeight</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'>&nbsp;</td><td>Line width in pixels</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Set line weight for grid line&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$graph-&gt;xgrid-&gt;SetWeight(2);</font>
</span><br>
<p>
<p>&nbsp; <p> &nbsp; <span style='font-size:110%;'><a name="_GRID_SHOW"><div style="border-top:solid black 2pt;background-color:lightblue;font-family:courier new;font-size:90%;font-weight:bold;"><b><font color="#000000">
function&nbsp;Show($aShowMajor,$aShowMinor)</font>
</b></div></a></span>

<span style='font-family:arial;font-size:90%;'><i>Specify if both major and minor grid should be displayed</i></span><p>

<table cellspacing=0 style='border:black solid 1pt;' width=100%>
<tr><th width=25%>Argument</th><th width=15%>Default</th><th width=60%>Description</th></tr>
<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aShowMajor</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
true</font>
</td><td>True=Show major grid lines</td></tr>

<tr><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
$aShowMinor</font>

</td><td style='border-right:black solid 1pt;font-family:courier;font-size:90%;font-weight:bold;'><font color="#000000">
false</font>
</td><td>True=Show minor grid lines</td></tr>
</table>

<div style="font-weight:bold;font-family:arial;font-size:85%;">Description</div>Specify if both major and minor grid should be displayed&nbsp;<br>

<div style="font-weight:bold;font-family:arial;font-size:85%;"><p>Example</div><span style="font-family:courier;font-size:85%;"><font color="#000000">
$graph-&gt;ygrid-&gt;Show();<br /></font>
</span><br>
<p> <hr> <p>